//
//  PlayerViewController.swift
//  DownloadTube
//
//  Created by Carlos on 12/10/14.
//  Copyright (c) 2014 Carlos. All rights reserved.
//

import UIKit
import AVKit
import AVFoundation

class PlayerViewController: AVPlayerViewController {
    
    var file:NSString!
    var items:[AVPlayerItem] = []
    
    override func viewDidLoad() {

        super.viewDidLoad()
        let videoURL = NSURL(fileURLWithPath: file)
        self.player = AVPlayer.playerWithURL(videoURL) as AVPlayer
        //self.player = AVQueuePlayer.queuePlayerWithItems(items) as AVQueuePlayer
        self.player.play()
    }

    override func didReceiveMemoryWarning() {

        super.didReceiveMemoryWarning()
    }
}